<template>
  <div>
    <div class="header">
      <slot name="title"></slot>
    </div>
    <div class="main">
      <div class="main_box" v-for="item in data" :key="item.id">
        <slot name="cont" :item="item"></slot>
        <!-- <solt name="content" :item="item"></solt> -->
      </div>
    </div>
  </div>
</template>

<script>
export default {
  props: {
    data: Array
  }
}
</script>

<style lang="less" scoped>
.header {
  border-top-left-radius: 10px;
  border-top-right-radius: 10px;
  width: 100%;
  height: 50px;
  padding: 0 15px;
  color: #fff;
  background-color: #009dff;
  .hobby {
    display: flex;
    justify-content: space-between;
    line-height: 50px;
  }
}
.main {
  padding-left: 20px;
  background-color: #fff;
  .main_box {
    display: flex;
    border-top: 1px solid #f3f3f3;
    justify-content: space-between;
    p {
      margin: 0;
      line-height: 40px;
    }
    span {
      line-height: 40px;
    }
  }
}
</style>